<?php
// $Id$
/**
 * @file
 * Modul za unos turistickih destinacija
 */

/**
 * Implementation of hook_help()
 */
function travel_help($path, $arg) {

  if ($path == 'admin/help#travel') {
    $txt = 'Modul za unos i prikaz turistickih destinacija. ';
    $replace = array();
    return '<p>'. t($txt, $replace) .'</p>';
  }
}

/**
 * Implementation of hook_menu()
 * kontinenti je normalan link u meniju, ostalo su callback koji se pozivaju uri-jem
 */
function travel_menu()
{
  $items = array();

  $items['kontinenti'] = array(
    'title' => 'Kontinenti',
    'page callback' => 'kontinenti',
    'access arguments' => array('access content'),
    'type' => MENU_NORMAL_ITEM
  );

  $items['drzave'] = array(
    'title' => 'Drzave',
    'page callback' => 'drzave',
    'access arguments' => array('access content'),
    'type' => MENU_CALLBACK
  );
  
  $items['mesta'] = array(
    'title' => 'Mesta',
    'page callback' => 'mesta',
    'access arguments' => array('access content'),
    'type' => MENU_CALLBACK
  );
  
  $items['hoteli'] = array(
    'title' => 'Hoteli',
    'page callback' => 'hoteli',
    'access arguments' => array('access content'),
    'type' => MENU_CALLBACK
  );
  
  $items['detalji'] = array(
    'title' => 'Detalji',
    'page callback' => 'detalji',
    'access arguments' => array('access content'),
    'type' => MENU_CALLBACK
  );

  return $items;
}

/**
 * Implementation of hook_theme()
 * Nesto kao ruter izmedju funkcija i tema
 */
function travel_theme()
{
    return array(
      'kontinenti_pregled' => array(
        'arguments' => array('kontinenti' => NULL),
      ),
      'drzave_pregled' => array(
        'arguments' => array('drzave' => NULL, 'galerija' => NULL, 'galerija_slike' => NULL),
      ),
      'mesta_pregled' => array(
        'arguments' => array('node_val' => NULL, 'mesta' => NULL, 'hoteli' => NULL, 'galerija' => NULL, 'galerija_slike' => NULL),
      ),
      'hoteli_pregled' => array(
        'arguments' => array('node_val' => NULL, 'hoteli' => NULL, 'galerija' => NULL, 'galerija_slike' => NULL),
      ),
      'detalji_pregled' => array(
        'arguments' => array('hotel' => NULL, 'galerija' => NULL, 'galerija_slike' => NULL),
      ),
    );
}

/**
*@desc Funkcija za prikaz kontinenata, pocetni korak u modulu, prikazuje smao razrede ove skolske godine
* poziva temu theme_kontinenti_pregled, sa parametrom $kontinenti (assoc niz kontinenata)
*/
function kontinenti()
{
  require_once './includes/custom_functions.php';
  $kontinenti = array();

  $result = db_query("SELECT node.nid AS nid,
   node_revisions.body AS body,
   node_revisions.title AS title,
   node_revisions.format AS format
 FROM node node 
 LEFT JOIN node_revisions node_revisions ON node.vid = node_revisions.vid
 WHERE node.type in ('kontinent')");
  while ($node = db_fetch_object($result))
  {
      $kontinenti[$node->nid] = $node->title;
  }

  return theme('kontinenti_pregled', $kontinenti);
}

/**
*@desc Prikazuje spisak kontinenata
*/
function theme_kontinenti_pregled($kontinenti)
{
    require_once './includes/custom_functions.php';

    $full_path = drupal_get_path('module', 'travel').'/travel.css';
    drupal_add_css($full_path);

    $page_content = '';

    foreach($kontinenti as $key => $value)
    {
      $page_content .= '<p>'.l($value, 'drzave', array('query' => array('id' => $key))).'</p>';
    }

    return $page_content;
}

function drzave()
{
  require_once './includes/custom_functions.php';
  $drzave = array();

  $result = db_query("SELECT node.nid AS nid,
   node_revisions.body AS body,
   node_revisions.title AS title,
   node_revisions.format AS format
 FROM node node 
 LEFT JOIN content_type_drzava node_data_field_kontinent ON node.vid = node_data_field_kontinent.vid
 LEFT JOIN node node_node_data_field_kontinent ON node_data_field_kontinent.field_kontinent_nid = node_node_data_field_kontinent.nid
 LEFT JOIN node_revisions node_revisions ON node.vid = node_revisions.vid
 WHERE (node.type in ('drzava')) AND (node_data_field_kontinent.field_kontinent_nid = %d)
", $_GET[id]);
  while ($node = db_fetch_object($result))
  {
      $drzave[$node->nid] = $node->title;
  }
  
  // GALERIJA
  list($galerija, $galerija_slike) = getGalerija($_GET[id]);

  return theme('drzave_pregled', $drzave, $galerija, $galerija_slike);
}

/**
*@desc Prikazuje tabelu spisak drzava
*/
function theme_drzave_pregled($drzave, $galerija, $galerija_slike)
{
    require_once './includes/custom_functions.php';

    $full_path = drupal_get_path('module', 'travel').'/travel.css';
    drupal_add_css($full_path);

    $page_content = '';

    foreach($drzave as $key => $value)
    {
      $page_content .= '<p>'.l($value, 'mesta', array('query' => array('id' => $key))).'</p>';
    }

    // GALERIJA
    $page_content .= "<p>".$galerija->title."</p>";
    $page_content .= "<p>".$galerija->body."</p>";
    
    $page_content .= $galerija_slike;
    
    return $page_content;
}

function mesta()
{
  require_once './includes/custom_functions.php';
  $mesta = array();
  $hoteli = array();

  $result = db_query("SELECT node.nid AS nid,
   node_revisions.body AS body,
   node_revisions.title AS title,
   node_revisions.format AS format
 FROM node node 
 LEFT JOIN content_type_mesto node_data_field_drzava ON node.vid = node_data_field_drzava.vid
 LEFT JOIN node node_node_data_field_drzava ON node_data_field_drzava.field_drzava_nid = node_node_data_field_drzava.nid
 LEFT JOIN node_revisions node_revisions ON node.vid = node_revisions.vid
 WHERE (node.type in ('mesto')) AND (node_data_field_drzava.field_drzava_nid = %d)
", $_GET[id]);
  while ($node = db_fetch_object($result))
  {
      $mesta[$node->nid] = $node->title;
  }
  
  $node_res = db_query("SELECT node.nid AS nid,
        node_revisions.title AS title,
        node_revisions.body AS body,
        files.filepath AS slika,
        node_revisions.format AS format
        FROM node node 
        LEFT JOIN node_revisions node_revisions ON node.vid = node_revisions.vid
        LEFT JOIN content_type_drzava ON node.vid = content_type_drzava.vid
        LEFT JOIN files ON content_type_drzava.field_slika_drzava_fid = files.fid
        WHERE node.vid = %d
        ", $_GET[id]);
  $node_val = db_fetch_object($node_res);

  $result = db_query("SELECT node.nid AS nid,
   node_revisions.body AS body,
   node_revisions.title AS title,
   node_data_field_mesto.field_zvezdica_value AS zvezdica,
   files.filepath AS slika,
   node_revisions.format AS format
 FROM node node 
 LEFT JOIN content_type_hotel node_data_field_mesto ON node.vid = node_data_field_mesto.vid
 LEFT JOIN node node_node_data_field_mesto ON node_data_field_mesto.field_mesto_nid = node_node_data_field_mesto.nid
 LEFT JOIN node_revisions node_revisions ON node.vid = node_revisions.vid
 LEFT JOIN files ON node_data_field_mesto.field_slika_fid = files.fid
 WHERE (node.type in ('hotel')) AND (node_data_field_mesto.field_mesto_nid IN (select  nid FROM content_type_mesto WHERE field_drzava_nid=%d))
", $_GET[id]);
  while ($node = db_fetch_object($result))
  {
      // CENOVNIK ZA HOTEL
      $result_cena = db_query("SELECT node.nid AS nid,
        node_revisions.title AS title,
        node_revisions.body AS body,
        node_revisions.format AS format
        FROM node node 
        LEFT JOIN content_type_cena node_data_field_hotel ON node.vid = node_data_field_hotel.vid
        LEFT JOIN node_revisions node_revisions ON node.vid = node_revisions.vid
        WHERE (node.type in ('cena')) AND (node_data_field_hotel.field_hotel_nid = %d)
        ", $node->nid);
        $cena = db_fetch_object($result_cena);
  
      $hoteli[$node->nid] = array('id'=>$node->nid, 'title'=>$node->title, 'body'=>$node->body, 'zvezdica'=>$node->zvezdica, 'slika'=>$node->slika, 'cena'=>$cena->body);
  }
  
  // GALERIJA
  list($galerija, $galerija_slike) = getGalerija($_GET[id]);

  return theme('mesta_pregled', $node_val, $mesta, $hoteli, $galerija, $galerija_slike);
}

/**
*@desc Prikazuje tabelu spisak mesta u drzavi
*/
function theme_mesta_pregled($node_val, $mesta, $hoteli, $galerija, $galerija_slike)
{
    require_once './includes/custom_functions.php';

    $full_path = drupal_get_path('module', 'travel').'/travel.css';
    drupal_add_css($full_path);

    $page_content = '';
    
    foreach($mesta as $key => $value)
    {
      $page_content .= '<p>'.l($value, 'hoteli', array('query' => array('id' => $key))).'</p>';
    }
    
    $page_content .= "<div id='block_container'>";
    $page_content .= "<h1>".$node_val->title."</h1>";
    $page_content .= "<div id='img'>";
    $page_content .= '<p>'.theme('imagecache', 'glavna_veliki', $node_val->slika, 'just a test image', 'test image').'</p>'; 
    $page_content .= '</div>';
    $page_content .= "<div id='text'>";
    $page_content .= "<p>".$node_val->body."</p>";
    $page_content .= "</div>";
    
    foreach($hoteli as $id => $values)
    {
      $page_content .= hotel_block($values);
    }
    
    $page_content .= "</div>";
    
    // GALERIJA
    $page_content .= "<div id='galerija_container'>";
    $page_content .= "<p>".$galerija->title."</p>";
    $page_content .= "<p>".$galerija->body."</p>";
    
    $page_content .= $galerija_slike;
    $page_content .= "</div>";

    return $page_content;
}

function hoteli()
{
  require_once './includes/custom_functions.php';
  $hoteli = array();

  $node_res = db_query("SELECT node.nid AS nid,
        node_revisions.title AS title,
        node_revisions.body AS body,
        files.filepath AS slika,
        node_revisions.format AS format
        FROM node node 
        LEFT JOIN node_revisions node_revisions ON node.vid = node_revisions.vid
  LEFT JOIN content_type_mesto ON node.vid = content_type_mesto.vid
        LEFT JOIN files ON content_type_mesto.field_slika_mesto_fid = files.fid
        WHERE node.vid = %d
        ", $_GET[id]);
  $node_val = db_fetch_object($node_res);
        
  $result = db_query("SELECT node.nid AS nid,
   node_revisions.body AS body,
   node_revisions.title AS title,
   node_data_field_mesto.field_zvezdica_value AS zvezdica,
   files.filepath AS slika,
   node_revisions.format AS format
 FROM node node 
 LEFT JOIN content_type_hotel node_data_field_mesto ON node.vid = node_data_field_mesto.vid
 LEFT JOIN node node_node_data_field_mesto ON node_data_field_mesto.field_mesto_nid = node_node_data_field_mesto.nid
 LEFT JOIN node_revisions node_revisions ON node.vid = node_revisions.vid
 LEFT JOIN files ON node_data_field_mesto.field_slika_fid = files.fid
 WHERE (node.type in ('hotel')) AND (node_data_field_mesto.field_mesto_nid = %d)
", $_GET[id]);
  while ($node = db_fetch_object($result))
  {
      // CENOVNIK ZA HOTEL
      $result_cena = db_query("SELECT node.nid AS nid,
        node_revisions.title AS title,
        node_revisions.body AS body,
        node_revisions.format AS format
        FROM node node 
        LEFT JOIN content_type_cena node_data_field_hotel ON node.vid = node_data_field_hotel.vid
        LEFT JOIN node_revisions node_revisions ON node.vid = node_revisions.vid
        WHERE (node.type in ('cena')) AND (node_data_field_hotel.field_hotel_nid = %d)
        ", $node->nid);
        $cena = db_fetch_object($result_cena);
  
      $hoteli[$node->nid] = array('id'=>$node->nid, 'title'=>$node->title, 'body'=>$node->body, 'zvezdica'=>$node->zvezdica, 'slika'=>$node->slika, 'cena'=>$cena->body);
  }
  
  // GALERIJA
  list($galerija, $galerija_slike) = getGalerija($_GET[id]);

  return theme('hoteli_pregled', $node_val, $hoteli, $galerija, $galerija_slike);
}

/**
*@desc Prikazuje tabelu spisak hotela u mestu
*/
function theme_hoteli_pregled($node_val, $hoteli, $galerija, $galerija_slike)
{
    require_once './includes/custom_functions.php';

    $full_path = drupal_get_path('module', 'travel').'/travel.css';
    drupal_add_css($full_path);

    $page_content = '';
    $page_content .= "<div id='block_container'>";
    $page_content .= "<h1>".$node_val->title."</h1>";
    $page_content .= "<div id='img'>";
    $page_content .= '<p>'.theme('imagecache', 'glavna_veliki', $node_val->slika, 'just a test image', 'test image').'</p>'; 
    $page_content .= '</div>';
    $page_content .= "<div id='text'>";
    $page_content .= "<p>".$node_val->body."</p>";
    $page_content .= "</div>";
    
    foreach($hoteli as $id => $values)
    {
      $page_content .= hotel_block($values);
    }
    
    $page_content .= "</div>";
    
    // GALERIJA
    $page_content .= "<div id='galerija_container'>";
    $page_content .= "<p>".$galerija->title."</p>";
    $page_content .= "<p>".$galerija->body."</p>";
    
    $page_content .= $galerija_slike;
    $page_content .= "</div>";

    return $page_content;
}

function detalji()
{
  require_once './includes/custom_functions.php';

  $result_detalji = db_query("SELECT node.nid AS nid,
   node_revisions.title AS title,
   node_revisions.body AS body,
   node_data_field_mesto.field_zvezdica_value AS zvezdica,
   files.filepath AS slika,
   node_revisions.format AS format
 FROM node node 
 LEFT JOIN node_revisions node_revisions ON node.vid = node_revisions.vid
 LEFT JOIN content_type_hotel node_data_field_mesto ON node.vid = node_data_field_mesto.vid
 LEFT JOIN files ON node_data_field_mesto.field_slika_fid = files.fid
 WHERE node_revisions.vid = %d
", $_GET[id]);
  $detalji = db_fetch_object($result_detalji);
  
  $result_cena = db_query("SELECT node.nid AS nid,
        node_revisions.title AS title,
        node_revisions.body AS body,
        node_revisions.format AS format
        FROM node node 
        LEFT JOIN content_type_cena node_data_field_hotel ON node.vid = node_data_field_hotel.vid
        LEFT JOIN node_revisions node_revisions ON node.vid = node_revisions.vid
        WHERE (node.type in ('cena')) AND (node_data_field_hotel.field_hotel_nid = %d)
        ", $detalji->nid);
        $cena = db_fetch_object($result_cena);
  
      $hotel = array('id'=>$detalji->nid, 'title'=> $detalji->title, 'body'=> $detalji->body, 'zvezdica'=> $detalji->zvezdica, 'slika'=> $detalji->slika, 'cena'=>$cena->body);
  
  // GALERIJA
  list($galerija, $galerija_slike) = getGalerija($_GET[id]);

  return theme('detalji_pregled', $hotel, $galerija, $galerija_slike);
}

/**
*@desc Prikazuje tabelu spisak detalja za hotel
*/
function theme_detalji_pregled($hotel, $galerija, $galerija_slike)
{
    require_once './includes/custom_functions.php';

    $full_path = drupal_get_path('module', 'travel').'/travel.css';
    drupal_add_css($full_path);

    $page_content = '';
    $page_content .= "<div id='block_container'>";
    $page_content .= "<h1>".$hotel[title]."</h1>";
    $page_content .= "<div id='img'>";
    $page_content .= '<p>'.theme('imagecache', 'glavna_veliki', $hotel[slika], 'just a test image', 'test image').'</p>'; 
    $page_content .= '</div>';
    $page_content .= "<div id='text'>";
    $page_content .= "<p>".$hotel[body]."</p>";
    $page_content .= "</div>";
    
    $page_content .= hotel_block($hotel);
    $page_content .= "</div>";
    
    // GALERIJA
    $page_content .= "<div id='galerija_container'>";
    $page_content .= "<p>".$galerija->title."</p>";
    $page_content .= "<p>".$galerija->body."</p>";
    
    $page_content .= $galerija_slike;
    $page_content .= "</div>";

    return $page_content;
}

function getGalerija($id)
{   
   $result_galerija = db_query("SELECT node.nid AS nid,
   node_revisions.title AS title,
   node_revisions.body AS body,
   node_revisions.format AS format
   FROM node node 
   LEFT JOIN content_field_za node_data_field_za ON node.vid = node_data_field_za.vid
   LEFT JOIN node_revisions node_revisions ON node.vid = node_revisions.vid
   WHERE (node.type in ('galerija')) AND (node_data_field_za.field_za_nid = %d)
   ", $id);
   $galerija =  db_fetch_object($result_galerija);
   
   $galerija_slike = '';
   if($galerija)
   {
     $slike_paths = array();
     $result_slike = db_query("SELECT files.filename, content_field_galery.field_galery_data 
     FROM files LEFT JOIN content_field_galery ON files.fid = content_field_galery.field_galery_fid LEFT JOIN node ON content_field_galery.vid = node.vid
     WHERE node.nid=$galerija->nid");
     while ($node = db_fetch_object($result_slike))
     {
       $slike_paths[] = '<a href="/sites/default/files/imagecache/veliki/'.$node->filename.'" rel="lightbox[roadtrip]"><img height="120" width="160" title="" alt="" src="/sites/default/files/imagecache/mali/'.$node->filename.'"/></a>';
     }
  
    foreach($slike_paths as $slike_path)
      $galerija_slike .= "<span class='light_container'>".$slike_path."</span>";
   }
  
  return array($galerija, $galerija_slike);
}

function hotel_block($hotel)
{
  $print = '';
  $print .= '<div class="block_hotel">
            <div class="hotel">
              <h1>';
  $print .= l($hotel[title], 'detalji', array('query' => array('id' => $hotel[id])));
  while($hotel[zvezdica]) 
  {
    $hotel[zvezdica] --;
    $print .= '<img height="17" width="20" alt="star" src="/sites/all/modules/travel/zvezdica.gif"/>';
  }             
  
        
  $print .= '</h1> ';
  
  $print .= '<table width="100%" cellspacing="0" cellpadding="0" border="0">
            <tbody><tr>
                <td width="180" valign="top" class="hotelThumb">';
  $print .= theme('imagecache', 'glavna_mali', $hotel[slika], 'just a test image', 'test image'); 
  $print .= '<p style="margin: 5px 10px; color: rgb(255, 153, 0);"></p></td>';
  
  
  $print .= '<td valign="top">
                    <p class="tipSobe">Tip sobe: 1/2, AI</p>';
                                               
  $print .= '<table cellspacing="0" cellpadding="0" border="0" class="cene"><tbody>';
  
  $cenas = explode('<br>', $hotel[cena]);
  $brojac = 0;
  foreach($cenas as $cena)
  {
    $cena_array = explode('/', $cena);
    if(!$cena_array[2])
      continue;
    if($brojac % 4 == 0)
      $print .= '<tr>';
    $print .= '<td>';
    $print .= '<p><span class="datum">'.$cena_array[0].'</span> '.$cena_array[1].' noći</p>';
    $print .= '<h3 style="margin-bottom: 0px;">'.l($cena_array[2].' €', 'detalji', array('query' => array('id' => $hotel[id])));
    $print .= '</h3>';
    $print .= '</td>';$brojac ++;
    if($brojac % 4 == 0)
      $print .= '</tr>';
  }
  if($brojac % 4 != 0)
      $print .= '</tr>';
  
                                    
   $print .= '</tbody></table>  
                </td>
            </tr>
        </tbody></table>';
       
       
       $print .= '</div></div>';  
  
  return $print;

}
/*<div class="block">
    <div class="hotel">
      <h1><a href="/page/winterTree/sr/Evropa/Turska/Kemer.html?view=accomodation&amp;id=1803"><span class="imeHotela">Akka Hotel Antedon Deluxe Hotel</span></a> <img height="17" width="20" alt="star" src="/img/star.gif"/><img height="17" width="20" alt="star" src="/img/star.gif"/><img height="17" width="20" alt="star" src="/img/star.gif"/><img height="17" width="20" alt="star" src="/img/star.gif"/><img height="17" width="20" alt="star" src="/img/star.gif"/> </h1> 
    
        <table width="100%" cellspacing="0" cellpadding="0" border="0">
            <tbody><tr>
                <td width="180" valign="top" class="hotelThumb"><img width="180" border="0" title="Akka Hotel Antedon Deluxe Hotel" alt="Akka Hotel Antedon Deluxe Hotel" src="/admin/accomodationImage.jpg?accId=1803&amp;thumb=1"/>
                        <p style="margin: 5px 10px; color: rgb(255, 153, 0);"><a href="/page/winterTree/sr/Evropa/Turska.html">Turska</a> / 
                        <a href="/page/winterTree/sr/Evropa/Turska/Kemer.html">Kemer</a></p>
                </td>
                <td valign="top">
                    <p class="tipSobe">Tip sobe: 1/2, AI<br/> Program: <a style="font-weight: normal;" href="/page/winterTree/sr/Evropa/Turska/Kemer.html?programmeId=272">Turska leto 2009</a></p>
                        <table cellspacing="0" cellpadding="0" border="0" class="cene">
                                <tbody><tr>
                                    <td>
                                        <p><span class="datum">07.06.</span> 10 noći</p>
                                        <h3 style="margin-bottom: 0px;"><a href="/page/winterTree/sr/Evropa/Turska/Kemer.html?view=accomodation&amp;id=1803&amp;programmeId=272">929 €</a></h3>  
                                    </td>
                                    <td>
                                        <p><span class="datum">17.06.</span> 11 noći</p>
                                        <h3 style="margin-bottom: 0px;"><a href="/page/winterTree/sr/Evropa/Turska/Kemer.html?view=accomodation&amp;id=1803&amp;programmeId=272">1089 €</a></h3> 
                                   </td>
                                   <td>
                                        <p><span class="datum">28.06.</span> 10 noći</p>
                                        <h3 style="margin-bottom: 0px;"><a href="/page/winterTree/sr/Evropa/Turska/Kemer.html?view=accomodation&amp;id=1803&amp;programmeId=272">1039 €</a></h3>       
                                  </td>
                                  <td style="border-right: 0px none;">
                                        <p><span class="datum">08.07.</span> 11 noći</p>
                                        <h3 style="margin-bottom: 0px;"><a href="/page/winterTree/sr/Evropa/Turska/Kemer.html?view=accomodation&amp;id=1803&amp;programmeId=272">1219 €</a></h3>     
                                 </td>
                                </tr>             
                                <tr>
                                    <td>
                                        <p><span class="datum">19.07.</span> 10 noći</p>
                                        <h3 style="margin-bottom: 0px;"><a href="/page/winterTree/sr/Evropa/Turska/Kemer.html?view=accomodation&amp;id=1803&amp;programmeId=272">1199 €</a></h3>    
                                 </td>
                                 <td>
                                        <p><span class="datum">29.07.</span> 11 noći</p>
                                        <h3 style="margin-bottom: 0px;"><a href="/page/winterTree/sr/Evropa/Turska/Kemer.html?view=accomodation&amp;id=1803&amp;programmeId=272">1299 €</a></h3> 
                                 </td>
                                 <td>
                                        <p><span class="datum">09.08.</span> 10 noći</p>
                                        <h3 style="margin-bottom: 0px;"><a href="/page/winterTree/sr/Evropa/Turska/Kemer.html?view=accomodation&amp;id=1803&amp;programmeId=272">1199 €</a></h3>       
                                 </td>
                                 <td style="border-right: 0px none;">
                                        <p><span class="datum">19.08.</span> 11 noći</p>
                                        <h3 style="margin-bottom: 0px;"><a href="/page/winterTree/sr/Evropa/Turska/Kemer.html?view=accomodation&amp;id=1803&amp;programmeId=272">1219 €</a></h3> 
                                        
                                 </td>
                                
                                
                                
                                </tr>
                            
                                <tr>
                                    <td>
                                        <p><span class="datum">30.08.</span> 10 noći</p>
                                        <h3 style="margin-bottom: 0px;"><a href="/page/winterTree/sr/Evropa/Turska/Kemer.html?view=accomodation&amp;id=1803&amp;programmeId=272">999 €</a></h3> 
                                        
                                 </td>
                                 <td>
                                        <p><span class="datum">09.09.</span> 11 noći</p>
                                        <h3 style="margin-bottom: 0px;"><a href="/page/winterTree/sr/Evropa/Turska/Kemer.html?view=accomodation&amp;id=1803&amp;programmeId=272">1089 €</a></h3>     
                                 </td>
                                 <td>
                                        <p><span class="datum">20.09.</span> 10 noći</p>
                                        <h3 style="margin-bottom: 0px;"><a href="/page/winterTree/sr/Evropa/Turska/Kemer.html?view=accomodation&amp;id=1803&amp;programmeId=272">899 €</a></h3> 
                                 </td>
                                <td style="border-right: 0px none;"> </td></tr>
                        </tbody></table>  
                </td>
            </tr>
        </tbody></table>
    </div>
</div>

*/